<?php 
	namespace Home\Controller;
	use Think\Controller;
	class GoodsController extends Controller{
		public function lanmu(){
			$obj = D('goods');
			
			$total = $obj->count();//获取当前记录总条数
			$per=16;
			$page = new \Component\Page($total,$per);
			$sql="select * from sw_goods ".$page->limit;
			$info=$obj->query($sql);
			
			// $info =	$obj->field('goods_id,goods_name,goods_price')->group('goods_price')->where('goods_price')->select();
			$pagelist = $page->fpage();
			$this->assign('info', $info);
			$this->assign('pagelist', $pagelist);
			$this->display();

		}		
		public function goods(){
			$a = $_GET['goods_id'];
			$data=array('goods_id'=>$a);
			$goods = D('goods');
			$info = $goods->where($data)->find();
			$this->assign('info',$info);
			$this->display();
		}
		public function shuangmo(){
			$this->display();
		}
		public function peijian(){
			$this->display();
		}
		public function huodong(){
			$this->display();
		}
		public function liuyan(){
			$this->display();
		}
	}

 ?>